{% extends "base.html" %}

{% block title %}Edit Global Certifications{% endblock %}
{% block crumb %}&rsaquo; Edit Global Certifications{% endblock %}

{% block content %}
  <h1>Editing Global Certifications</h1>
  <h2>Warning: Deleting a certification will remove it from all users</h2>
  {% if message %}
  <br>
  <font color="RED"><b>{{message}}</b></font>
  <br>
  {% endif %}
  <table>
	  <tr><td>

<h2>Remove Certifications</h2>
  <table>
	  <tr>
		  <td>Certification</td>
		  <td>Priority</td>
		  <td>Delete?</td>
	  </tr>
  <form enctype="multipart/form-data" method="post" action="">{% csrf_token %}
  {% for attr in attrs %}
  <tr>
	  <td>{{attr.name}}</td>
	  <td>{{attr.priority}}</td>
	  <td><input type="checkbox" name="attr" value="{{attr.pk}}"></td>
  </tr>
  {% endfor %}
    </table>
	<input type="submit" name="del_attr" value="Delete Selected" />
	  </form>

</td><td></td><td>
	 <h2>Add Certification</h2>
  <form enctype="multipart/form-data" method="post" action="">{% csrf_token %}
      {{ form.as_p }}
      <input type="submit" name="add_attr" value="Add Attribute">
  </form>
	  </td></tr>
	</table>
{% endblock %}